class KDT:
    def __init__(self):
        pass

    def open_browser(self, target, url):
        print('打开{}浏览器输入网址{}'.format(target, url))

    def input(self, target, content):
        print('在{}输入内容:{}'.format(target, content))

    def click(self, target):
        print("在{}进行点击操作".format(target))

    def check(self, target):
        print("验证{}对象是否存在".format(target))

    def start(self):
        with open("./login.txt", "r", encoding='utf-8') as f:
            content = f.read().split("\n")

            for line_data in content:

                action = line_data.split(',')[0]  #操作
                parmas = line_data.split(",")[1::]
                if hasattr(self, action):
                    getattr(self, action)(*parmas)


if __name__ == '__main__':
    kdt = KDT()
    kdt.start()

